
package cn.com.nes.mybatis.agent.crm.mapper;

import cn.com.nes.mybatis.agent.crm.entity.Customer;
import cn.com.nes.site.entity.vo.crm.QueryCustomerPageVo;
import cn.com.nes.site.entity.vo.crm.ReplenishCustomerInfoVO;
import cn.com.nes.site.service.crm.customer.bo.CustomerPageBO;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import org.apache.ibatis.annotations.Param;

import java.util.Date;
import java.util.List;

/**
 * @author yishuai
 * @description 针对表【customer】的数据库操作Mapper
 * @createDate 2024-03-05 11:30:06
 * @Entity cn.com.nes.mybatis.agent.crm.entity.Customer
 */
public interface CustomerMapper extends BaseMapper<Customer> {

    List<Customer> allCustomerPage(Page<Customer> page, @Param("vo") QueryCustomerPageVo vo);


    List<Customer> customerPage(Page<Customer> page, @Param("bo") CustomerPageBO bo);

    List<String> getCustomerIdListByAreaCode(@Param("shortAreaCode") String shortAreaCode, @Param("projectId") Long projectId);

    /**
     * 补充安装工单下的客户信息
     */
    Integer replenishCustomerInfo(@Param("vo") ReplenishCustomerInfoVO vo);


    void deleteByIds(@Param("ids")List<String> ids, @Param("operateUserId") Long operateUserId, @Param("operateDate") Date operateDate);

    List<String> getCustomerIdListByCustomerName(@Param("customerName") String customerName);

    Customer getCustomerByIdCard(@Param("idCardNumber")String   idCardNumber,@Param("projectUuid") String projectUuid,@Param("xzqhdm") String xzqhdm,@Param("customerName") String customerName,@Param("phone") String phone);

    Customer getCustomerByPhone(@Param("vo")Customer vo);
}



